package command;

import command.CeilingFan.*;
import command.garageDoor.GaraDoorCloseCommand;
import command.garageDoor.GarageDoor;
import command.garageDoor.GarageDoorOpenCommand;
import command.light.Light;
import command.light.LightOffCommand;
import command.light.LightOnCommand;
import command.strereo.StereoOffWithCDCommand;
import command.strereo.StereoOnWithCDCommand;
import command.strereo.Strereo;

/**
 * Created by lenovo on 2018/1/3.
 */
public class RemoteLoaderWithUndoCeiling {
    public static void main(String[] args){

        RemoteControlWithUndo remoteControl=new RemoteControlWithUndo();

        CeilingFan ceilingFan=new CeilingFan("Living Room");

        CeilingFanHighCommand ceilingFanHighCommand=new CeilingFanHighCommand(ceilingFan);
        CeilingFanMediumCommand ceilingFanMediumCommand=new CeilingFanMediumCommand(ceilingFan);
        CeilingFanLowCommand ceilingFanLowCommand=new CeilingFanLowCommand(ceilingFan);
        CeilingFanDownCommand ceilingFanDownCommand=new CeilingFanDownCommand(ceilingFan);

        remoteControl.setCommand(0,ceilingFanHighCommand,ceilingFanLowCommand);
        remoteControl.setCommand(1,ceilingFanMediumCommand,ceilingFanDownCommand);

        remoteControl.onButtonWasPushed(0);
        remoteControl.undoButtonWasPushed();
        remoteControl.offButtonWasPushed(0);

        remoteControl.offButtonWasPushed(1);
        remoteControl.onButtonWasPushed(1);
        remoteControl.undoButtonWasPushed();
        remoteControl.onButtonWasPushed(2);
        remoteControl.offButtonWasPushed(2);
        remoteControl.onButtonWasPushed(3);
        remoteControl.offButtonWasPushed(3)
        ;





    }
}
